<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
	<title>免费领取优惠券</title>
	<meta name="viewport" content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,width=device-width,initial-scale=1.0"/>
	<script src="https://cdn.jsdelivr.net/npm/vue"></script>
	<script src="https://cdn.bootcss.com/jquery/3.3.1/jquery.min.js"></script>
	<script typet="text/javascript" src="https://res.wx.qq.com/open/js/jweixin-1.3.2.js"></script>
	<script src="/js/mobileSelect.min.js"></script>
	<link rel="stylesheet" type="text/css" href="https://api.uu235.com/web/front/static/css/style.css" />
	<link rel="stylesheet" type="text/css" href="/css/mobileSelect.css" />
</head>
<body>

<div id="wrap">
	<div class="center" style="margin-top: 350px;">
		<div class="main-content" style="margin:0;padding:0">
			<div>

				<ul style="padding:35px">
					<li>
						<input required  type="tel" maxlength="11" v-model="phone" style=" text-align: center; line-height: 48px; height: 48px; width: 100%; border: none; outline: none; border-radius: 40px;" placeholder="请输入手机号" />
					</li>
					<li style="margin-top:20px;">
						<span @click="submitOrder" class="ui-btn" style=" background: rgb(221,12,34); border: none; color: #fff; border-radius: 40px;">立即领取</span>
					</li>
				</ul>

				<p style="margin:10px; text-align:center;color:#fff;padding-bottom:20px;">上葡团，买点好酒犒劳自己</p>
			</div>
		</div>
	</div>
</div>

<script>
    function getUrlParam(name) {
        var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)");
        var r = window.location.search.substr(1).match(reg);
        if (r != null) return unescape(r[2]);
        return null;
    }
    var vm = new Vue({
        el: '#wrap',
        data: {
			phone:'',
        },
        mounted:function () {},
        methods: {
            submitOrder() {
                var _this = this;
                $.ajax({
                    type:"post",
                    url:"https://api.uu235.com/index/inviterIntention",
                    data:{
                        phone: _this.phone,
                        inviter_id: <?php echo $inviter_id;?>,
                    },
                    success: function(data){
                        alert(data.msg);
                        wx.miniProgram.switchTab({url:'/pages/index/index'});
                    }
                });
            }
        }
    })
</script>
<style scoped>
	body{
		background: url('/images/liquanbg.png') center top no-repeat #ffe7ed;
		background-size: cover;
	}
	.title {
		display: flex;
		line-height: 3rem;
		margin: 1rem;
		font-size: 1.2rem;
		text-align: center;
		border: rgb(102, 102, 102) 1px solid;
		border-radius: 4px;
	}
	.title li {
		flex: 1;
	}
	.title li.active {
		background: rgb(102,102,102);
		color: #fff;
	}

	.buy-count {
		display: flex; position: relative; padding: 1rem; margin-top: 1rem;
	}
	.buy-count:before,.buy-count:after {
		position: absolute;
		left: 0;
		right: 0;
		height: 1px;
		background: #f2f2f2;
		content: '';
	}
	.buy-count:before {
		top: 0;
	}
	.buy-count:after {
		bottom: 0;
	}

	.input-order {
		width: 78%;
		border: none;
		outline: none;
		text-align: right;
	}
	.counter {
		display: flex;
		position: absolute;
		top: -.6rem;
		width: 8rem;
		right: 0;
		height: 2.5rem;
		line-height: 2rem;
		text-align: center;
		border-radius: 4px;
	}

	.counter input {
		width: 3rem;
		text-align: center;
		border: none;
		border-left: #e3e3e3 1px solid;
		border-right: #e3e3e3 1px solid;
		outline: none;
	}

	.counter span {
		flex-basis: 3rem;
	}
	.ticket {
		position: relative;
		padding-top: 1rem;
	}
	.ticket:before {
		position: absolute;
		left: 0;
		right: 0;
		top: 0;
		height: 10px;
		content: '';
	}
</style>
</body></html>
